<template>
  <div v-if="$route.meta.useFrame != undefined && $route.meta.useFrame == false ">
     <RouterView></RouterView>
  </div>
  <div v-if="$route.meta.useFrame == undefined || $route.meta.useFrame == true">
  <el-container>
    <el-header>
      <el-row class="row-bg" justify="space-between">
      <el-col :span="6" class="logo">
      <img src="./assets/logo.jpg" alt="">
      </el-col>
      <el-col :span="6"><div class="grid-content ep-bg-purple-light" /></el-col>
      <el-col :span="6">
       <el-dropdown :hide-on-click="false">
      <span class="el-dropdown-link">
        萧炎<el-icon class="el-icon--right"><arrow-down /></el-icon>
      </span>
      <template #dropdown>
        <el-dropdown-menu>
          <el-dropdown-item>个人中心</el-dropdown-item>
          <el-dropdown-item>账户与安全</el-dropdown-item>
          <el-dropdown-item>常见问题</el-dropdown-item>
          <el-dropdown-item>关于我们</el-dropdown-item>
          <el-dropdown-item divided command="logout">注销</el-dropdown-item>
        </el-dropdown-menu>
      </template>
    </el-dropdown>
      </el-col>
    </el-row>
    </el-header>
    <el-container>
      <el-aside width="180px">
        <Menu></Menu>
      </el-aside>
      <el-main>
        <!--路由的出口-->
        <!-- <router-view></router-view> -->
        <RouterView></RouterView>
      </el-main>
    </el-container>
  </el-container>
  </div>
</template>
<script setup lang="ts">
import Menu from './components/Menu.vue';
</script>

<style scoped>
*{
  margin: 0px;
  padding: 0px;
}
.el-header {
  width: 100%;
  height: 40px;
  background-color: #c6e2ff;
  padding-left:0px;
}
.logo img{
  width: 180px;
  height: 40px;
}
.el-dropdown{
  float: right;
  padding-top: 10px;
}
</style>
